﻿<?xml version="1.0" encoding="utf-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
    xmlns:msxsl="urn:schemas-microsoft-com:xslt" exclude-result-prefixes="msxsl"
>
  <xsl:output method="xml" indent="yes" encoding="utf-8" media-type="text/xml" />
  <xsl:param name="relrootpath"/>
  <xsl:param name="eventname" />

  <xsl:template match="/TalksConext">

    <Transform>
      <xsl:apply-templates select="Event[@Name=$eventname]">
      </xsl:apply-templates>
    </Transform>
  </xsl:template>

  <xsl:template match="Event[@Name='TalksReply']">
    <Content>
      <div class="left">
        <control kind="useravatar" AvatarType="Thumbnail" ShowNickName="false">
          <xsl:attribute name="UserId" >
            <xsl:value-of select="ReplierUserId"/>
          </xsl:attribute>
        </control>

      </div>
      <div>
        <control kind="userlink">
          <xsl:attribute name="UserId">
            <xsl:value-of select="ReplierUserId"/>
          </xsl:attribute>
        </control>
        <xsl:text>对你的话题"</xsl:text>
        <a>
          <xsl:attribute name="href">
            <xsl:value-of select="$relrootpath"/>
            <xsl:text>/Mod/Talks/Thread.aspx?t=</xsl:text>
            <xsl:value-of select="ThreadId"/>
          </xsl:attribute>
          <xsl:value-of select="PostTitle" />
        </a>
        <xsl:text>"作出了新的回复。</xsl:text>
        <div class="msgact">
          <div class="nss ns-doc">
            <xsl:text> </xsl:text>
          </div>
          <span class="iconlabel">
          <a>
            <xsl:attribute name="href">
              <xsl:value-of select="$relrootpath"/>
              <xsl:text>/Mod/Talks/Thread.aspx?t=</xsl:text>
              <xsl:value-of select="ThreadId"/>
            </xsl:attribute>
            查看详细
          </a>
          </span>
        </div>
      </div>
    </Content>
  </xsl:template>

</xsl:stylesheet>
